import {
    createRouter,
    createWebHashHistory
} from "vue-router"

const routes = [{
        path: '/',
        name: 'main',
        redirect: '/index',
        component: () => import('../views/main.vue'),
        children: [{
                path: '/index',
                component: () => import('../views/index.vue'),
                name: 'index',
            },
            {
                path: '/News',
                component: () => import('../views/News.vue'),
                name: 'News',
            },
            {
                path: '/ClassVideo',
                component: () => import('../views/ClassVideo.vue'),
                name: 'ClassVideo',
            },
            {
                path: '/NewsDetails',
                component: () => import('../views/NewsDetails.vue'),
                name: 'NewsDetails',
            },
            {
                path: '/Introduction',
                component: () => import('../views/Introduction.vue'),
                name: 'Introduction',
            },
            {
                path: '/School',
                component: () => import('../views/School.vue'),
                name: 'School',
            }
        ],


    },
    {
        path: '/Search',
        component: () => import('../views/Search.vue'),
        name: 'Search'
    },
    


]
export const router = createRouter({
    history: createWebHashHistory(),
    routes: routes
})

export default router